import {queryCategories} from '@/api/goods'
export const useCategoryStore = defineStore('category',()=>{
    const categories = ref([]);
    async function fetchCategories(){
        categories.value = await queryCategories();
    }
    fetchCategories()
    return {
        categories,
        fetchCategories
    }
})